package com.ymtms.arrivalofgoods.service.impl;

import com.netflix.discovery.converters.Auto;
import com.ymtms.arrivalofgoods.dao.GoodsbillMasterMapper;
import com.ymtms.arrivalofgoods.pojo.GoodsbillEvent;
import com.ymtms.arrivalofgoods.pojo.GoodsbillMaster;
import com.ymtms.arrivalofgoods.service.GoodsbillEventService;
import com.ymtms.arrivalofgoods.service.GoodsbillMasterService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class GoodsbillMasterServiceImpl implements GoodsbillMasterService {
    @Autowired
    private GoodsbillMasterMapper goodsbillMasterMapper;

    @Override
    public GoodsbillMaster findMasterByBillcode(String billcode) {
        return goodsbillMasterMapper.queryGoodsbillMasterByCode(billcode);
    }

    @Override
    public void modifyStatusByGmid(Integer gmid) {
        goodsbillMasterMapper.updateSettleByGmid(gmid);
    }

    @Override
    public GoodsbillMaster findOneMasterByGmid(Integer gmid) {
        return goodsbillMasterMapper.selectByPrimaryKey(gmid);
    }
}
